<?php
/**
 * Implements hook_rules_event_info().
 */
function shushengyuan_rules_event_info() {
  return [
    'shushengyuan_rules_event_order_pay_finish_callback' => [
      'label' => t('订单支付完成'),
      'group' => t('shushengyuan'),
      'variables' => [
        'order' => [
          'type' => 'shusy_store_order',
          'label' => t('订单'),
        ],
      ],
    ],
  ];
}

//
///**
// * Implements hook_rules_condition_info().
// */
//function shushengyuan_rules_condition_info() {
//  return [
//    'rules_condition_text_compare' => [
//      'label' => t('Textual comparison'),
//      'parameter' => [
//        'text1' => ['label' => t('Text 1'), 'type' => 'text'],
//        'text2' => ['label' => t('Text 2'), 'type' => 'text'],
//      ],
//      'group' => t('Rules'),
//    ],
//  ];
//}

/**
 * Implements hook_rules_action_info().
 */
function shushengyuan_rules_action_info() {
  return [
    'shushengyuan_rules_action_profit_period' => [
      'label' => t('店铺账期解锁'),
      'parameter' => [
        'order' => [
          'type' => 'shusy_store_order',
          'label' => t('Order'),
        ],
      ],
      'group' => t('shushengyuan'),
    ],
  ];
}
